import request from "@/utils/request";

interface orderListParams {
  current?: number,
  pageSize?: number,
  orderSn?: string,
  productName?: string,
  startTime?: number,
  endTime?: number,
  email?: string,
  status?: number,
}
export const getOrder = (params:orderListParams) => {
  return request({
    url: "/api/order/queryOrderList",
    method: "get",
    params
  })
}
interface deliveryParams {
  orderId?: number,
  deliveryCompany?:string,
  deliverySn?:string,
}
export const delivery = (data:deliveryParams) => {
  return request({
    url: "/api/order/delivery",
    method: "post",
    data
  })
}

export const getDeliveryOptions = () => {
  return request({
    url: "/api/order/deliveryOptions",
    method: "get",
  })
}
